<p class="modal-title">Create/Modify Admin Account</p>
<hr/>
<div class="modal-content">
	<div class="well">
	<form>
  <div class="form-group">
    <label>LoginId</label>
    
      <input type="text" id="code" placeholder="Use this id for login" class="form-control ng-pristine ng-valid modal-input" ng-model="user.code" ng-change="closeAllTooltip()"  data-toggle="popover" data-placement="right" data-content="Please input LoginID" title="" data-original-title="Error">
  </div>

  <div class="form-group">
    <label>Password</label>
    
      <input type="password" id="password" placeholder="Password" class="form-control ng-pristine ng-valid modal-input" ng-model="user.password" ng-change="closeAllTooltip()"  data-toggle="popover" data-placement="right" data-content="Please Input Password" title="" data-original-title="Error">
  </div>

  <div class="form-group">
    <label>Password Again</label>
    
      <input type="password" id="re-password" placeholder="Password Agamin" class="form-control ng-pristine ng-valid modal-input" ng-model="user.re_password" ng-change="closeAllTooltip()" data-toggle="popover" data-placement="right" data-content="Passwords not consistant" title="" data-original-title="Error">
  </div>

  <div class="form-group">
    <!-- Text input-->
    <label for="input01">Admin Role</label>
    
      <select class="input-large" ng-model="user.subrole">
        <option value="Super Admin">Super Admin</option>
        <option value="Sub-Region Admin">Sub-Region Admin</option>
        <option value="Training Admin">Training Admin</option>
        <option value="GC People Admin">GC People Admin</option>
      </select>
      <!-- <input type="text" placeholder="" ng-model="formData.payment" class="input-large"> -->
      <p class="help-block"></p>
    
  </div>
  <div class="form-group" ng-if="user.subrole=='Sub-Region Admin'">
    <!-- Text input-->
    <label for="input01">Sub-Region</label>
     <select class="form-control" ng-options="div.name for div in regions track by div.id" ng-model="user.region" >
                                        <option value="">--- Sub-Region ---</option>
                                    </select>
      <p class="help-block"></p>
    
  </div>

  <div class="btn-group modal-buttons">
    <div class="pull-right">
      <a class="btn btn-primary ok-button" ng-click="createUser()">Submit</a>
      <a class="btn btn-primary cancel-button" ng-click="closeDialog()">Cancel</a>
    </div>
  </div>
</form>
</div>
</div>